<?php

/**
 * livreur actions.
 *
 * @package    frigospeed
 * @subpackage livreur
 * @author     0
 * @version    SVN: $Id: actions.class.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $
 */
class livreurActions extends sfActions
{
 /**
  * Executes index action
  *
  * @param sfRequest $request A request object
  */
  public function executeIndex(sfWebRequest $request)
  {
    //$this->forward('default', 'module');
		$this->utilisateurs = Doctrine_Core::getTable('Utilisateur');
		$this->utilisateurs = Doctrine_Query::create()->select('u.*')
			->from('Utilisateur u')
			->where("u.type = 'livreur'")
			->execute();
	}
	
		public function executeShow(sfWebRequest $request)
  {
    //$this->forward('default', 'module');
		$this->commandes = Doctrine_Core::getTable('Commande');
		$this->commandes = Doctrine_Query::create()->select('c.*')
		->from('Commande c')
		->where("utilisateur_livreurid = ".$request->getParameter('id'))
		->execute();
  }
}
